﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TestScaner
{
    class Program
    {
        static void Main(string[] args)
        {
            try
            {
                Scaner scaner = new Scaner();
                scaner.daFisierSursa(@"F:\Downloads\Tema_nr2_MardariRadu\ALex\Form1.cs");

                bool eof = false;

                while (eof != true)
                {
                    AtomLexical atom = scaner.nextToken(out eof);
                    Console.WriteLine("lexema<{0}> Atom<{1}>",atom.lexema,atom.tipAtom);
                }
            }
            catch (Exception exp)
            {
                Console.WriteLine("\nEroare\n"+exp.ToString()+"\n\n");
            }

        }
    }
}
